﻿using System;
using System.Text;

using BizElements.Core;
using BizElements.Core.ProviderComponents;

namespace BizElements.Core.SQLite
{
    sealed class SQLiteTableRenderer : ITableRenderer
    {
        public void RenderTableName(IDbTable table, StringBuilder output)
        {
            // Special characters must be enclosed in brackets.
            output.Append("[");
            output.Append(table.TableName);
            output.Append("]");
        }

        public void RenderAlias(IDbTable table, StringBuilder output)
        {
            // Special characters must be enclosed in brackets.
            output.Append("[");
            output.Append(table.Alias);
            output.Append("]");
        }       
    }
}